#!/usr/bin/env python
#coding=utf-8



""" logger 日志 """

import logging

import logging.handlers

handler = logging.handlers.RotatingFileHandler("D:/666.txt ");

formater = logging.Formatter("%(asctime)s -  %(name)s - %(filename)s:%(lineno)d - %(message)s")

handler.setFormatter(formater)

logger = logging.getLogger('main')

logger.addHandler(handler)

logger.setLevel(logging.DEBUG)

logger.debug("the logger out")



